import sys
id=input("请输入id(不超过8位):")
if len(id)>8 or len(id)<1:
    print("id长度错误！")
    exit()
for i in range(0,len(id)):
    if ord(id[i])<48 or (ord(id[i])>57 and ord(id[i])<65) or (ord(id[i])>90 and ord(id[i])!=95 and ord(id[i])<97) or ord(id[i])>122:
        print("id格式错误！")
        exit()

email=input("请输入邮箱:")
if (not "@" in email) or (not "." in email):
    print("邮箱格式错误！")
    exit()
temp = email.split("@")
if len(temp)>2:
    print("邮箱格式错误！")
    exit()
if "." in temp[0]:
    print("邮箱格式错误！")
    exit()
if temp[1].find(".")>2:
    print(temp[1].find("."))
    print("邮箱格式错误!")
    exit()
identity=input("请输入身份证号:")
if len(identity)!=18:
    print("身份证号格式错误！")
    exit()
for i in range(0,len(identity)-1):
    if ord(identity[i])<48 and ord(identity[i])>57:
        print("身份证号格式错误！")
        exit()
if ord(identity[-1])!=88 and ord(identity[-1])!=120 and (ord(identity[-1])<48 or ord(identity[-1])>57):
    print("身份证号码格式错误！")
    exit()
name=input("请输入姓名:")
if len(name)<1 or len(name)>4:
    print("姓名格式错误！")
    exit()
for i in name:
    if not '\u4e00' <= i <= '\u9fa5':
        print("姓名必须是中文！")
        exit()
print("注册成功！")